# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-mimeparse
_pkgname=python-mimeparse
pkgver=1.6.0
pkgrel=6
pkgdesc='A module provides basic functions for parsing mime-type names and matching them against a list of media-ranges.'
url='https://pypi.org/project/python-mimeparse/#files'
arch=('any')
license=('MIT')
depends=('python2')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('cc2ec8059034fc224c59bffeb77e7fd0ba86b753373c8daf3a182fd56d647f0b96d7bacb6708be285dd7e246ebc19b813e2bfb8ac79a86f6d4e702c223f5187e')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

